package model.person;

import java.util.ArrayList;
import java.util.List;

public class Employee extends Person {
	private float salary;
	private List<Function> functions = new ArrayList<Function>();

	public Employee(String firstName, String lastname, float salary,
			Function function) {
		super(firstName, lastname);
		this.salary = salary;
		functions.add(function);
	}

	public List<Function> getFunctions() {
		return functions;
	}

	public void addFunction(Function function) {
		functions.add(function);
	}

	public float getSalary() {
		return salary;
	}

	public void setSalary(float salary) {
		this.salary = salary;
	}

	@Override
	public String toString() {
		return "Employee [firstName=" + firstName + ", lastname=" + lastname + ", salary=" + salary + ", functions=" + functions + "]";
	}
}
